package com.peach.service;

import com.peach.pojo.News;
import com.peach.pojo.NewsType;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface NewsService {
    List<News> selectAllNewsNoConditions();
    List<News> selectAllNews(Integer newsTypeId, String newsTitle,String newsAuthor);
    Boolean updateOneNews(News news);
    Boolean deleteOneNews(Integer newsId);
    Boolean insertOneNews(News news);

    //根据标题类型查
    List<News> selectNewsByTypeId(Integer newsId);
    //根据文章ID查详情
    News selectOneNews(Integer newsId);
    List<NewsType> selectAllNewsTypes();
    List<News> selectNewsByTypeIdReturnNews(Integer newsId);
}
